// 导入基地址
import request from "@/utils/requset";

// 导入格式转换
import YAML from "json2yaml";

// 封装一个记录库位点的接口
export const recordApi = (data) => {
  return request({
    url: "/mwrobot_location_point/add",
    method: "POST",
    data: YAML.stringify(data),
  });
};

// 封装一个删除库位的接口
export const removeApi = (id) => {
  return request({
    url: "/mwrobot_location_point/delete",
    method: "POST",
    data: YAML.stringify(id),
  });
};

//新建一个获取库位列表的接口
export const gainApi = () => {
  return request({
    url: "/mwrobot_location_point/get",
  });
};


//新建一个修改库位列表的接口
export const updataApi = (data) => {
  return request({
    url: '/mwrobot_location_point/update',
    method: "POST",
    data: YAML.stringify(data)
  })
}